public class TargetSum {

    public int process(int[] nums, int target, int i) {
        int sum = 0;
        if (i == nums.length) {
            return target == 0 ? 1 : 0;
        }
        sum += process(nums, target - nums[i], i+1);
        sum += process(nums, target + nums[i], i+1);
        return sum;
    }



    
}
